<?php
abstract class LoginObserverPlus implements SplObserver{
	private $login;

	function __construct(LoginPlus $login){
		$this->login = $login;
		$login->attach($this);
	}

	function update( SplSubject $subject){
		if($subject === $this->login){
			$this->doUpdate($subject);
		}
	}

	abstract function doUpdate(LoginPlus $login);
}